package vn.com.bookstore.database.sobject;

import vn.com.bookstore.database.SDatabaseObject;
import vn.com.bookstore.database.adbException;

@SuppressWarnings("serial")
public class Link extends SDatabaseObject {
	public static final String CLASS_UNIQUE = "Link";
	public static final int NUM_FIELDS = 3;

	public String url = "";
	public String json = "";
	public String time = "";

	public Link(int index, String... values) {
		super(index, values);
		try {
			if (values.length != NUM_FIELDS)
				throw new adbException(CLASS_UNIQUE + " length values invalid!");
		} catch (adbException e) {
			e.printStackTrace();
		}
		url = values[0];
		json = values[1];
		time = values[2];
	}

	@Override
	public String[] getValues() {
		values[0] = url;
		values[1] = json;
		values[2] = time;
		return values;
	}
}
